package com.example.businesscalcproject;


import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.Window;
import android.widget.TextView;

public class MainActivity extends Activity {

	@Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        this.requestWindowFeature(Window.FEATURE_NO_TITLE);
        setContentView(R.layout.activity_main);
        
        TextView dl = (TextView) findViewById(R.id.depreciacao_linear);
        dl.setOnClickListener(new OnClickListener() {
		
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				depreciacao_linear();
			}
		});
        TextView adc = (TextView) findViewById(R.id.acumulacao_capital);
        adc.setOnClickListener(new OnClickListener() {
		
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				acumulacao_capital();
			}
		});
        
        TextView dc = (TextView) findViewById(R.id.desconto_comercial);
        dc.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				desconto_comercial();
			}
		});
        
        TextView dr = (TextView) findViewById(R.id.desconto_racional);
        dr.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				desconto_racional();
			}
		});
        
        TextView va = (TextView) findViewById(R.id.valor_atual);
        va.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				fator_valor_atual();
			}
		});
        
        TextView dsa = (TextView) findViewById(R.id.depreciacao_soma_algarismo);
        dsa.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				depre_soma_algarismo();
			}
		});
        
        TextView ac = (TextView) findViewById(R.id.amortizacao_constante);
        ac.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				amortizacao_constante();
			}
		});
        
        TextView jsc = (TextView) findViewById(R.id.juros_simples_composto);
        jsc.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				juros_simples_composto();
			}
		});
        
        TextView tp = (TextView) findViewById(R.id.tabela_price);
        tp.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				tabela_price();
			}
		});
    }
    public void acumulacao_capital(){
    	Intent intent = new Intent(this, Acumulacao_Capital.class);
    	startActivity(intent);
    }
    public void depreciacao_linear(){
    	Intent intent = new Intent(this, Depreciacao_Linear.class);
    	startActivity(intent);
    }
    public void desconto_comercial(){
    	Intent intent = new Intent(this, Desconto_Comercial.class);
    	startActivity(intent);
    }
    public void desconto_racional(){
    	Intent intent = new Intent(this, Desconto_Racional.class);
    	startActivity(intent);
    }
    public void fator_valor_atual(){
    	Intent intent = new Intent(this, Valor_Atual.class);
    	startActivity(intent);
    }
    public void depre_soma_algarismo(){
    	Intent intent = new Intent(this, Depreciacao_Soma_Algarismo.class);
    	startActivity(intent);
    }
    public void amortizacao_constante(){
    	Intent intent = new Intent(this, Amortizacao_Constante.class);
    	startActivity(intent);
    }
    public void juros_simples_composto(){
    	Intent intent = new Intent(this, Juros_Simples_Composto.class);
    	startActivity(intent);
    }
    public void tabela_price(){
    	Intent intent = new Intent(this, Tabela_Price.class);
    	startActivity(intent);
    }
    
    
    
}
